//
//  ViewController.h
//  myhuibao
//
//  Created by lijun on 13-2-4.
//  Copyright (c) 2013年 myhuibao. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "WQTableViewController.h"
#import "LeveyPopListView.h"
#import "ASIHTTPRequest.h"
#import "ASIFormDataRequest.h"
#import <CoreLocation/CoreLocation.h>
#import <MapKit/MapKit.h>

@class RequestLoadingView;

@interface NearSearchViewController : WQTableViewController <WQTableViewDelegate,LeveyPopListViewDelegate,CLLocationManagerDelegate,MKReverseGeocoderDelegate>
{
    int pageIndex;
    int returnCount;
    int selectIndex;
    int distance;
    int cuisineId;
    int avgConsumeID;
    int typeId;
    int score;
    NSMutableArray *arrayDistance;
    NSMutableArray *arrayScore;
    NSMutableArray *arrayCuisine;
    NSMutableArray* arrayMerchant;
    NSMutableArray *arrayOrderBy;
    NSMutableArray *arrayTypeTicket;
    int orderByType;
    bool isShowed;
    bool isCuisineFinished;
    bool isSearchFinished;
    bool isSearchMoreFinished;
    bool isConsumeFinished;
    int _selectedIndex,_selectedIndex1,_selectedIndex2,_selectedIndex3,
    _selectedIndex4, _selectedIndex5,_selectedIndex6;
    int _selectedTypeIndex,_selectedTypeIndex1;

    CLLocationManager * locationManager;
    RequestLoadingView *loadingView;
}
@property (assign,nonatomic) int iNearType;
@property (assign,nonatomic) int iViewMerchantType;
@property (strong, nonatomic) IBOutlet UITableView *mainTable;
- (IBAction)showDistance:(id)sender;
@property (assign,nonatomic) int typeId;
@property (strong, nonatomic) IBOutlet UILabel *lbAddress;
- (IBAction)showCuisine:(id)sender;
@property (unsafe_unretained) ASIHTTPRequest *reqCuisine;
@property (unsafe_unretained) ASIFormDataRequest *reqSearch;
@property (unsafe_unretained) ASIFormDataRequest *reqSearchMore;
@property (unsafe_unretained) ASIHTTPRequest *reqConsume;
@property (strong, nonatomic) NSMutableArray *arrayDistrict;
@property (strong, nonatomic) NSMutableArray *arrayCuisineType;
@property (strong, nonatomic) NSMutableArray *arrayConsume;
@property (strong, nonatomic) NSMutableArray *arrayType;
@property (strong, nonatomic) IBOutlet UIButton *BtnType;
@property (strong, nonatomic) IBOutlet UIView *ControlView;
@property (strong, nonatomic) IBOutlet UIButton *BtnChoose;
- (IBAction)OnChoose:(id)sender;

- (IBAction)showMap:(id)sender;
- (IBAction)doLocation:(id)sender;

- (IBAction)doBack:(id)sender;
- (IBAction)showType:(id)sender;
@property (strong, nonatomic) IBOutlet UILabel *lbFirst;
@property (strong, nonatomic) IBOutlet UILabel *lbSecond;
@property (strong, nonatomic) IBOutlet UILabel *lbThird;
@property (strong, nonatomic) IBOutlet UIButton *btnThird;
- (IBAction)OnClickType:(id)sender;
@property (strong, nonatomic) IBOutlet UIButton *btnFirst;

@end
